package time;

import java.time.Clock;
import java.time.Instant;
import java.time.ZoneId;

public class ClockDemo {

	public static void main(String[] args) {
		Clock c1 = Clock.systemDefaultZone();
		System.out.println(c1.getZone());
		
		Instant i1 = c1.instant();
		Instant i2 = Instant.now();

		ZoneId asiaKolkata = ZoneId.of("Asia/Kolkata");
		Clock c2 = Clock.system(asiaKolkata);
		System.out.println(c2.getZone());
		System.out.println(c2);
		
	}

}
